package com.hshx.client;

import com.hshx.VO.PositionVo;
import com.hshx.pojo.Position;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.cloud.openfeign.SpringQueryMap;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

@FeignClient(name = "gateway",
        path = "/systemService",
        contextId = "PositionClient")
public interface PositionClient {
    @RequestMapping("/addPositionOne")
    boolean addPositionOne(@SpringQueryMap Position position);

    @RequestMapping("/removePosition")
    boolean removePosition(@RequestParam(name = "position_id") int position_id);

    @RequestMapping("/updatePosition")
    boolean updatePosition(@SpringQueryMap Position position);

    @RequestMapping("/getAllPosition")
    List<Position> getAllPosition();

    @RequestMapping("/getPosition")
    Position getPosition(@RequestParam(name = "position_id") int position_id);

    @RequestMapping("/getPositionVoList")
    List<PositionVo> getPositionVoList();

}
